import type { Component } from 'vue'
import {
  ElCascader,
  ElCheckboxGroup,
  ElCheckbox,
  ElColorPicker,
  ElDatePicker,
  ElInput,
  ElInputNumber,
  ElRadioGroup,
  ElRate,
  ElSelect,
  ElSelectV2,
  ElSlider,
  ElSwitch,
  ElTimePicker,
  ElTimeSelect,
  ElTransfer,
  ElAutocomplete,
  ElDivider,
  ElTreeSelect,
  ElUpload,
  ElInputTag
} from 'element-plus'
import { InputPassword } from '@/components/InputPassword'
import { Editor } from '@/components/Editor'
import { empInput } from '@/components/emp'
import { enumDicItem, dictItem, treeDicItem } from '@/components/base'
import { ComponentName } from '../types'
import { deptSelect } from '@/components/unit'
import { imageUpBtn } from '@/components/fileUp'
import { companySelect } from '@/components/company/'
import { roleSelect } from '@/components/role'
import { IconPicker } from '@/components/IconPicker/'
import { formInput, formColChiose } from '@/customForm/components/form'
import { flowInput } from '@/flow/components/flow'
import { Label, NumRange, ObjectKeySet } from '../control'
const componentMap: Recordable<Component, ComponentName> = {
  RadioGroup: ElRadioGroup,
  RadioButton: ElRadioGroup,
  CheckboxGroup: ElCheckboxGroup,
  CheckboxButton: ElCheckboxGroup,
  Input: ElInput,
  Autocomplete: ElAutocomplete,
  InputNumber: ElInputNumber,
  Checkbox: ElCheckbox,
  Select: ElSelect,
  Cascader: ElCascader,
  Switch: ElSwitch,
  Slider: ElSlider,
  TimePicker: ElTimePicker,
  DatePicker: ElDatePicker,
  Rate: ElRate,
  ColorPicker: ElColorPicker,
  Transfer: ElTransfer,
  Divider: ElDivider,
  TimeSelect: ElTimeSelect,
  SelectV2: ElSelectV2,
  InputPassword: InputPassword,
  Editor: Editor,
  TreeSelect: ElTreeSelect,
  Upload: ElUpload,
  TreeDicItem: treeDicItem,
  EnumItem: enumDicItem,
  DicItem: dictItem,
  DeptSelect: deptSelect,
  EmpInput: empInput,
  CompanySelect: companySelect,
  ImageUp: imageUpBtn,
  RoleSelect: roleSelect,
  IconPicker: IconPicker,
  ObjectKeySet: ObjectKeySet,
  InputTag: ElInputTag,
  NumRange: NumRange,
  FormInput: formInput,
  FlowInput: flowInput,
  FormColChiose: formColChiose,
  Label: Label
}

export { componentMap }
